package top.llcngu.config;

import org.springframework.cloud.client.loadbalancer.LoadBalanced;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.client.RestTemplate;

/**
 * @author llcngu
 * @version v1.0
 * @description 注入需要的实例
 * @date 2021/4/3 16:49
 * @since v1.0
 */
@Configuration
public class ConsumerConfig {

    /**
     * @description 注入RestTemplate实例
     * @author llcngu
     * @date 2021/4/3 16:57
     * @return RestTemplate
     */
    @Bean
    @LoadBalanced
    public RestTemplate restTemplate() {
        return new RestTemplate();
    }
}
